DeHackEd

DeHackEd (or DHE for short) is an editor originally created for vanilla Doom that allows the operation of the executable to be changed. It was developed by Greg Lewis. Hit points, sounds, frame sequences, text strings and several other miscellaneous values can be changed. Modifications can be distributed in the form of DeHackEd "patches" which can be applied to the executable. In order to do this, DeHackEd has the ability to generate an exact copy of the Doom or Doom II executable, which by default is called.

The most common patches add fast monsters and weapons, player-seeking self-detonating barrels, and so on. However, more balanced and artistic modifications can and have been made. Even though many advanced effects can be achieved with DeHackEd, it does not offer the complete flexibility that a custom source port can provide. Monster AI and armor classes are fixed for example.

Older DeHackEd patches use a binary format of data to be applied to an executable file using the DeHackEd patching utility. Later versions of DeHackEd save their patches in a human-readable plain text format that can be edited with any text editor.



Boom included the ability to load DeHackEd patches and affect changes to the game upon startup without any modification to the executable file. Other source ports added similar functionality, and command-line loadable DeHackEd support is now common with most modern source ports. Boom also provided the BEX (Boom EXtended) extensions for DeHackEd support. BEX allows greater flexibility in string editing, application of codepointers to any frame, and extra codepointers.

Another extension to DeHackEd editing targeted at source ports later emerged in the form of the DEHEXTRA standard, which specifies additional things, sprites, frames, and sounds which are available with specified numbers and are unused by default, allowing the addition of entirely new objects without replacing the game's built-in content.

History

 * v1.0 was released around June 19, 1994. It is the first release.
 * v1.1
 * v1.2 was released around June 24, 1994.
 * v1.3 was released around July 1, 1994.
 * v2.0 (beta) was released around August 24, 1994.
 * v2.0 was released on September 12, 1994.
 * v2.1 was released on November 2, 1994.
 * v2.2 was released on December 14, 1994.
 * v2.3 was released on February 26, 1995.
 * v2.4 was released around May 14, 1995.
 * v3.0 was released on August 29, 1995.
 * v3.0a was released on September 4, 1995. It is the final release of DeHackEd by Greg Lewis.

Also, a separate version was created by John A. Kaczmarski Jr. for Final Doom. It was released as v3.1 on February 26, 1997. However, it is based on DeHackEd v2.3 and therefore lacks some of the features of the newer versions.

DoomHack
Besides being the default name of the executable DeHackEd generates as a copy of the Doom II executable, DoomHack, stylized as is also an umbrella moniker to describe any custom executable that applies a DeHackEd patch to the Doom executable, commonly that of Doom II. However, the shareware release of Doom may also be used when a user wants to create a patch. In DeHackEd's, one can specify a custom name for the resulting executable, set by the user.

Several WADs, primarily those released as partial conversions and total conversions such as Hacx, Mordeth and Strain, use either custom installer programs or primitive batch files to apply their patch to a copy of the Doom II executable. This is done through the main DeHackEd program in conjunction with DeuSF and NWT to append extra flats and textures to the patch, but can also be used to simply merge the patch and the executable together. These installers also changed the resulting executables to a custom name to distinguish them from the main Doom or Doom II executable. Not every batch file or installer did this, however, or confusingly changed the DeHackEd exectuable back to Doom II.

This method was the primary means of modifying the engine before the existence of source ports, as nowadays the user simply loads the patch alongside their port of choice, negating the use of a custom DeHackEd engine.

Supplying a modified DeHackEd executable with a release instead of relying on an installer/batch file or an instruction (or a combination of these) did also exist and was (and is) considered illegal due to it relying on id Software's executables. Supplying a patch instead avoids this by including only a minimum amount of novel information to apply to the original file and requiring the end user to possess the original. This also leaves the choice to the end user whether to play it in a source port or on vanilla Doom.

In the present day, for those projects that target pure vanilla/DOS compatibility, DoomHack may still be used. Because of this, and because of its prior function as a means to modify the engine, DoomHack can be seen as a predecessor to the later source ports, that made modifications possible before the Doom source code was released.

VULD
The launcher VULD makes heavy use of DoomHack to automatically apply DeHackEd patches and graphics from PWADs to a new executable that can also be automatically renamed using the name of the patch as its template.

Thing numbers
When modifying things in DeHackEd, each thing type has an associated number. These correspond to the index in the thing info table inside the executable ( found in in the Doom source code). This number is different from the DoomEd number used to identify things when editing levels. Note that the DeHackEd index starts at 1, while the table index starts at 0.

For convenience, the table also lists the default DoomEd number associated to each thing, as well as the names used in popular editors, the identifier used in the Doom source code, and the corresponding ZDoom class name (which are used in UMAPINFO).

Linux version
DeHackEd (version 2.3) was ported to in 1995 by Sam Lantinga as Linux Doom Hack Editor or ldhe. Compared to DOS, LDHE is slower and has no mouse support, but it does support running on and the Linux console. X11 and SVGA Doom Linux binaries are supported. It also supports SGI Doom 1.8, allowing DeHackEd to be used and compiled on a SGI machine alongside a specifically compiled Deutex binary.

Heretic version
In 1995, Greg Lewis created a version of DeHackEd for Heretic called Heretic Hack Editor (HHE). It was based on DHE v2.2. However, he abandonded work on it after the release of HHE v1.1 (based on DHE v2.3). The copy of the executable that HHE applies its patches to is named HereHack.

Trivia

 * The executable hack Doom32 is understood by DeHackEd when the executable is renamed to . It will warn the user that the checksum does not match, but it will otherwise accept Doom32 as a substitute and can be used to create Doom32-compatible DoomHack executables.